gl renderer: Don't copy matrix/offset of color matrix nodes into ops
authorTimm Bäder <mail@baedert.org>
Mon, 16 Dec 2019 05:32:36 +0000 (06:32 +0100)
committerTimm Bäder <mail@baedert.org>
Tue, 7 Jan 2020 16:27:15 +0000 (17:27 +0100)
gsk/gl/gskglrenderer.c
gsk/gl/gskglrenderops.c
gsk/gl/opbuffer.h

index b64338a919825c11b94d5d16eccf3c88b788181c..c0734532cc83517c5c4f1273de9f3e9a8b685d36 100644 (file)
@@ -2492,10 +2492,10 @@ apply_color_matrix_op (const Program       *program,
   float mat[16];
   float vec[4];
   OP_PRINT (" -> Color Matrix");
-  graphene_matrix_to_float (&op->matrix, mat);
+  graphene_matrix_to_float (op->matrix, mat);
   glUniformMatrix4fv (program->color_matrix.color_matrix_location, 1, GL_FALSE, mat);
 
-  graphene_vec4_to_float (&op->offset, vec);
+  graphene_vec4_to_float (op->offset, vec);
   glUniform4fv (program->color_matrix.color_offset_location, 1, vec);
 }
 
index da725b8bbf9362c5d9a561c9f8ad94d7af62f453..1e245212e4545500a9ce3f89413a8d073d21dfe8 100644 (file)
@@ -653,8 +653,8 @@ ops_set_color_matrix (RenderOpBuilder         *builder,
   current_program_state->color_matrix.offset = *offset;
 
   op = ops_begin (builder, OP_CHANGE_COLOR_MATRIX);
-  op->matrix = *matrix;
-  op->offset = *offset;
+  op->matrix = matrix;
+  op->offset = offset;
 }
 
 void
index 8578bc108be644a7fe7cc76b96a73e3462d8c883..e5198bb0b3a262bdb82701c0175aad44a4cd3ba7 100644 (file)
@@ -118,8 +118,8 @@ typedef struct
 
 typedef struct
 {
-  graphene_matrix_t matrix;
-  graphene_vec4_t offset;
+  const graphene_matrix_t *matrix;
+  const graphene_vec4_t *offset;
 } OpColorMatrix;
 
 typedef struct